Websydian v6.1 online documentationOnline documentation - Websydian v6.5

UUID Entity

Scoped name

WSYBASE/UUID

Overview

We have identified issues with record-locking  in the standard Plex surrogate entities (in certain variants) that means that we can't be certain that an assigned surrogate is unique.

The UUID entity provides an easy way to create an entity that is known by a universally unique identifier (UUID) - which removes the need for using the surrogate entities.

The UUID's are  much longer than the Plex surrogates - which of course means that they will take up more space in the database. However, to us this seems a small price to pay to be sure that the keys are unique.

You need to be aware that where the surrogates were assigned in a way where you by sorting in key order would get the records in the order they were created. This is not the case using UUID's, they are by nature random. This means that if you want to be able to sort the records in creation order, you should add a creation timestamp to your entity.

Implementing

You implement the UUID functionality by simply inheriting from the abstract entity and replace the abstract UUID field with your own key field.

Source Object Verb Target Object
MyUUIDEntity is a ENT WSYBASE/UUID
MyUUID is a FLD WSYBASE/UUID
MyUUIDEntity replaces FLD

...by FLD

WSYBASE/UUID

MyUUID